package com.hph.demo;

import io.netty.util.CharsetUtil;

import java.io.Serializable;
import java.util.Arrays;

/**
 * @author 10499
 */
public class MessageDTO implements Serializable {

    private static final long serialVersionUID = 42342645745235L;

    private int len;

    private byte[] name;

    public int getLen() {
        return len;
    }

    public void setLen(int len) {
        this.len = len;
    }

    public byte[] getName() {
        return name;
    }

    public void setName(byte[] name) {
        this.name = name;
    }

    @Override
    public String toString() {
        return "MessageDTO{" +
                "len=" + len +
                ", name=" + new String(name, CharsetUtil.UTF_8) +
                '}';
    }
}
